import fetch from '@/api'

//列表
export function getAuditMatterList(params) {
    return fetch({
        method: 'get',
        url: `/inventoryAdjust/page`,
        params,
    })
}

// 编辑
export function updateAuditMatter(id,data) {
    return fetch({
        method: 'POST',
        url: `/inventoryAdjust/update/${id}`,
        data
    })
}

// 删除
export function deleteAuditMatter(id) {
    return fetch({
        method:'delete',
        url:`/inventoryAdjust/${id}`
    })
}

//提交
export function submitAuditMatter(id, data) {
    return fetch({
        method: 'put',
        url: `/inventoryAdjust/${id}`,
        data,
    })
}

//审核通过
export function auditPass(id, data) {
    return fetch({
        method: 'post',
        url: `/inventoryAdjust/check/${id}`,
        data,
    })
}

//退回
export function auditFailed(id, data) {
    return fetch({
        method: 'post',
        url: `/inventoryAdjust/return/${id}`,
        data,
    })
}

//首页库房平台
export function getInventoryCount(params) {
    return fetch({
        method: 'get',
        url: `/inventory/count`,
        params,
    })
}
